<template>
    <el-select v-model="_value" placeholder="Select">
        <el-option v-for="item in options" :key="item[valueKey]" :label="item[labelKey]" :value="item[valueKey]" />
        <template #footer>
            hello
        </template>
    </el-select>
</template>
  
<script setup>
import { ref, computed } from 'vue'

const emit = defineEmits()

const props = defineProps({
    modelValue: [String, Number],
    labelKey: {
        type: String,
        default: 'name'
    },
    valueKey: {
        type: String,
        default: 'id'
    },
    options: Array
})

let _value = computed({
    get() { return props.modelValue },
    set(val) { emit('update:modelValue', val) }
})
</script>
  
<style lang="scss" scoped>

</style>